<form id="lab_form" name="lab_form" class="form-horizontal">
    <div class="box-body">
        <div class="col-md-12">
            <div class="form-group">
                <label class="col-sm-3 control-label">实验名称<span style="color:red">*</span></label>
                <div class="col-sm-8">
                    <input type="text" class="form-control" id="name" name="name" placeholder="实验名称">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">审核人<span style="color:red">*</span></label>
                <div class="col-sm-8">
                    <input type="icheck-checkbox" data-text="firstName" readonly="readonly" name="verifiers"  class="square-blue"
                           data-flag="urlSelector" data-src="/lab/get/WORKFLOW-VERIFY">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">签发人<span style="color:red">*</span></label>
                <div class="col-sm-8">
                    <input type="icheck-checkbox" data-text="firstName" name="approvers"  class="square-blue"
                           data-flag="urlSelector" data-src="/lab/get/WORKFLOW-APPROVE">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">备注</label>
                <div class="col-sm-8">
                                    <textarea name="remark" id="remark" placeholder="请填写备注"
                                              class="form-control"></textarea>
                </div>
            </div>
        </div>
    </div>
    <div class="box-footer text-right">
        <button type="submit" class="btn btn-primary" data-btn-type="save">提交流程</button>
    </div>
</form>
<script>
    //
    var labform;
    var id = "${id?default(0)}";
    $(function () {
        //初始化表单
        labform = $("#lab_form").form();
        labform.initComponent();
        if (id != 0) {
            ajaxPost(basePath + "/lab/find/" + id, null, function (data) {
                labform.initFormData(data);
                if (data.taskState == "1") {
                    $("input[name='approvers']").attr("readonly", "readonly");
                }
            })


        }
    });

</script>
